package cn.lingyangwl.agile.msg.push.model.rqrs.receiver;

import cn.lingyangwl.agile.model.constants.ValidationCons;
import cn.lingyangwl.framework.data.mate.annotations.FieldSensitive;
import cn.lingyangwl.framework.data.mate.fieldsensitive.enums.StrategyType;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotEmpty;

/**
 * 消息接收者
 *
 * @author shenguangyang
 */
@Getter
@Setter
public class ReceiverBase {
    @NotEmpty(message = ValidationCons.NOT_EMPTY)
    @ApiModelProperty(value = "接收者姓名")
    private String name;

    @NotEmpty(message = ValidationCons.NOT_EMPTY)
    @ApiModelProperty(value = "手机号")
    @FieldSensitive(strategy = StrategyType.MOBILE_PHONE)
    private String phone;

    @NotEmpty(message = ValidationCons.NOT_EMPTY)
    @ApiModelProperty(value = "邮箱")
    @FieldSensitive(strategy = StrategyType.EMAIL)
    private String email;

    @ApiModelProperty(value = "微信公众号openId")
    @FieldSensitive(strategy = StrategyType.RESERVE_6)
    private String wxMpOpenId;

    @ApiModelProperty(value = "企业微信应用openId")
    @FieldSensitive(strategy = StrategyType.EMAIL)
    private String qyWxOpenId;

    @ApiModelProperty(value = "备注")
    private String remark;
}
